package com.jzy.gulimall.cart.service;

import com.jzy.gulimall.cart.vo.CartItemVo;
import com.jzy.gulimall.cart.vo.CartVo;

import java.util.List;
import java.util.concurrent.ExecutionException;

/**
 * @author jzy
 * @date 2020/9/18 14:21
 */
public interface CartService {
    CartItemVo addToCart(Long skuId, Integer num) throws ExecutionException, InterruptedException;

    CartItemVo getCartItem(Long skuId);

    CartVo getCart();

    void mergeCart(String userKey, Long id);

    void checkItem(Long skuId, Integer check);

    void countItem(Long skuId, Integer num);

    void deleteItem(Long skuId);

    List<CartItemVo> getUserCartItem();
}
